<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt"  prefix="fmt"%>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>趣生活论坛</title>
	<link rel="stylesheet" href="${pageContext.request.contextPath}/static/style/front/css/base.css"/>
	<link rel="stylesheet" href="${pageContext.request.contextPath}/static/style/front/css/style.css"/>
</head>

<body>

<div class="header">
    <div class="head wrap">
          <div class="logo fl"><a href=""><img src="${pageContext.request.contextPath}/static/style/front/images/logo.png"/></a></div>
          <div class="head-right fr">
              <div class="head-a fr">
          <% if(session.getAttribute("users")==null){ %>
                   <div class="head-a3 login-click fl"><a href="${pageContext.request.contextPath}/login">登录</a></div>
                   <div class="head-a4 reg-click fl"><a href="${pageContext.request.contextPath}/login">注册</a></div>          
              
            <% }else{%>             		 
              <div class="tbt fl">
              		<a href="${pageContext.request.contextPath}/collection">
              			<img src="${pageContext.request.contextPath}/${users.picture}" style="display: inline-block;height: auto;max-width: 100%;"/>
                   </a>     
               </div>
             <%} %> 
             </div>
              <div class="clearfix"></div>
              <div class="nav fr">
                  <ul>
                       <li><a href="#">首页</a></li>
                       <li><a href="#">文章</a>
                           <div class="sub-nav">
                                <div class="bich-top"></div>
                                 <div class="bich">
                                     <a href="#">服饰</a>
                                     <a href="#">美食</a>
                                     <a href="#">出行</a>
                                     <a href="#">约会</a>
                                 </div>
                           
                           </div>
                       </li>
                       <li class="nav-cut"><a href="#">社区</a></li>
                       <li><a href="#">课程</a></li>
                       <li><a href="#">活动</a></li>
                       <li><a href="#">联系我们</a></li>
                  </ul>
              </div>
              <div class="clearfix"></div>
          </div>
    </div>
</div>


<div class="content">
    <div class="idx-banner">
            <div class="fullSlide">
                   <div class="box">
                        <ul>
                           <li style="background:url(${pageContext.request.contextPath}/static/style/front/upload/lun.jpg) no-repeat center center;">
                                  <a href="javascript:;"></a></li>
                           <li style="background:url(${pageContext.request.contextPath}/static/style/front/upload/lun1.jpg) no-repeat center center;">
                                  <a href="javascript:;"></a></li>
                           <li style="background:url(${pageContext.request.contextPath}/static/style/front/upload/lun2.jpg) no-repeat center center;">
                                  <a href="javascript:;"></a></li>
                        </ul>
                    </div>
                    <div class="hbox">
                        <ul></ul>
                    </div> 
            </div>
    </div>
    
    <div class="wrap">
			<div class="kg-box">
				<div class="kg-title">
					<h1 style="font-size: 40px">版块列表</h1>
				</div>
					<c:forEach items="${list}" var="item" varStatus="status">
						<c:if test="${status.count%2==1}">
							<div class="kg" style="margin-top:10px;">
						</c:if>																		
								<a href="${pageContext.request.contextPath}/community/${item.id}">
								<div class="kg-a fl" style="float:left; margin-right:100px;">
										<div class="kg-a1 fl">
											<img
												src="${pageContext.request.contextPath}/${item.picture}" style="display: inline-block;height: auto;max-width: 100%;"/>
										</div>
										<div class="kg-a2 fl">
											<div class="kg-a3" style="font-size: 30px">${item.name}</div>
											<div class="kg-a4" style="font-size: 30px">帖子数：${item.topiccount}</div>
											<div class="kg-a5" style="font-size: 30px">评论数：${item.commentcount}</div>
											<div class="kg-a6">
												<span><img
													src="${pageContext.request.contextPath}/static/style/front/images/col-c1.jpg" />0</span>
												<span><img
													src="${pageContext.request.contextPath}/static/style/front/images/col-c2.jpg" />3</span>
												<em><img
													src="${pageContext.request.contextPath}/static/style/front/images/col-c3.jpg" /></em>
												<em><img
													src="${pageContext.request.contextPath}/static/style/front/images/col-c4.jpg" /></em>
												<em><img
													src="${pageContext.request.contextPath}/static/style/front/images/col-c5.jpg" /></em>
											</div>
											<div class="kg-t">
												<img
													src="${pageContext.request.contextPath}/static/style/front/images/kg-t.png" />
											</div>
										</div>
									</div></a>
									
							<c:if test="${status.count%2==0}">	
								</div>		
						</c:if>
					</c:forEach>																
														         
          <div class="kg-box">
                 <div class="kg-title" style="font-size: 40px">精品帖子推荐</div>
                    <div class="kg">
                     <a href=""><div class="kg-a fl">
                   <div class="kg-a2 fl">
                         <div class="kg-a3">只要生活有期盼，一个人也可以很好。</div>
                         <div class="kg-a4">水果大人</div>
                         <div class="kg-a5">发表于 2015-11-02</div>
                         <div class="kg-a6">
                                    <span><img src="${pageContext.request.contextPath}/static/style/front/images/col-c1.jpg">0</span>
                                    <span><img src="${pageContext.request.contextPath}/static/style/front/images/col-c2.jpg">3</span>
                                    <em><img src="${pageContext.request.contextPath}/static/style/front/images/col-c3.jpg"></em>
                                    <em><img src="${pageContext.request.contextPath}/static/style/front/images/col-c4.jpg"></em>
                                    <em><img src="${pageContext.request.contextPath}/static/style/front/images/col-c5.jpg"></em>
                         </div>
                         <div class="kg-y"><img src="${pageContext.request.contextPath}/static/style/front/images/kg-y.png"></div>
                    </div>
                    <div class="kg-a1 fl"><img src="${pageContext.request.contextPath}/static/style/front/upload/kg-a3.jpg"></div>
               </div></a>
                    <div class="kg-b fl">
                    <a href=""><div class="kg-c1 fl"><img src="${pageContext.request.contextPath}/static/style/front/upload/kg-a4.jpg"></div>
                    <div class="kg-a2 fl">
                         <div class="kg-a3">只要生活有期盼，一个人也可以很好。</div>
                         <div class="kg-a4">水果大人</div>
                         <div class="kg-a5">发表于 2015-11-02</div>
                         <div class="kg-a6">
                                    <span><img src="${pageContext.request.contextPath}/static/style/front/images/col-c1.jpg">0</span>
                                    <span><img src="${pageContext.request.contextPath}/static/style/front/images/col-c2.jpg">3</span>
                                    <em><img src="${pageContext.request.contextPath}/static/style/front/images/col-c3.jpg"></em>
                                    <em><img src="${pageContext.request.contextPath}/static/style/front/images/col-c4.jpg"></em>
                                    <em><img src="${pageContext.request.contextPath}/static/style/front/images/col-c5.jpg"></em>
                         </div>
                         <div class="kg-t"><img src="${pageContext.request.contextPath}/static/style/front/images/kg-t.png"></div>
                    </div></a>
                    <a href=""><div class="kg-c2 fl"><img src="${pageContext.request.contextPath}/static/style/front/upload/kg-a5.jpg"></div></a>
               </div>
               
               
                  </div>
                      <div class="kg">
               <a href=""><div class="kg-a fl">
                    <div class="kg-a1 fl"><img src="${pageContext.request.contextPath}/static/style/front/upload/kg-a5.jpg"></div>
                    <div class="kg-a2 fl">
                         <div class="kg-a3">只要生活有期盼，一个人也可以很好。</div>
                         <div class="kg-a4">水果大人</div>
                         <div class="kg-a5">发表于 2015-11-02</div>
                         <div class="kg-a6">
                                    <span><img src="${pageContext.request.contextPath}/static/style/front/images/col-c1.jpg">0</span>
                                    <span><img src="${pageContext.request.contextPath}/static/style/front/images/col-c2.jpg">3</span>
                                    <em><img src="${pageContext.request.contextPath}/static/style/front/images/col-c3.jpg"></em>
                                    <em><img src="${pageContext.request.contextPath}/static/style/front/images/col-c4.jpg"></em>
                                    <em><img src="${pageContext.request.contextPath}/static/style/front/images/col-c5.jpg"></em>
                         </div>
                         <div class="kg-t"><img src="${pageContext.request.contextPath}/static/style/front/images/kg-t.png"></div>
                    </div>
               </div></a>
               
               <a href=""><div class="kg-a fl">
                    <div class="kg-a2 fl">
                         <div class="kg-a3">只要生活有期盼，一个人也可以很好。</div>
                         <div class="kg-a4">水果大人</div>
                         <div class="kg-a5">发表于 2015-11-02</div>
                         <div class="kg-a6">
                                    <span><img src="${pageContext.request.contextPath}/static/style/front/images/col-c1.jpg">0</span>
                                    <span><img src="${pageContext.request.contextPath}/static/style/front/images/col-c2.jpg">3</span>
                                    <em><img src="${pageContext.request.contextPath}/static/style/front/images/col-c3.jpg"></em>
                                    <em><img src="${pageContext.request.contextPath}/static/style/front/images/col-c4.jpg"></em>
                                    <em><img src="${pageContext.request.contextPath}/static/style/front/images/col-c5.jpg"></em>
                         </div>
                         <div class="kg-y"><img src="${pageContext.request.contextPath}/static/style/front/images/kg-y.png"></div>
                    </div>
                    <div class="kg-a1 fl"><img src="${pageContext.request.contextPath}/static/style/front/upload/kg-a6.jpg"></div>
               </div></a>
               <a href=""><div class="kg-a2 fl">
                         <div class="kg-a3">只要生活有期盼，一个人也可以很好。</div>
                         <div class="kg-a4">水果大人</div>
                         <div class="kg-a5">发表于 2015-11-02</div>
                         <div class="kg-a6">
                                    <span><img src="${pageContext.request.contextPath}/static/style/front/images/col-c1.jpg">0</span>
                                    <span><img src="${pageContext.request.contextPath}/static/style/front/images/col-c2.jpg">3</span>
                                    <em><img src="${pageContext.request.contextPath}/static/style/front/images/col-c3.jpg"></em>
                                    <em><img src="${pageContext.request.contextPath}/static/style/front/images/col-c4.jpg"></em>
                                    <em><img src="${pageContext.request.contextPath}/static/style/front/images/col-c5.jpg"></em>
                         </div>
                         <div class="kg-y"><img src="${pageContext.request.contextPath}/static/style/front/images/kg-y.png"></div>
               </div></a>
          </div>
                 
                 
          </div> 
          
          <div class="idx-btm"><a href=""><img src="${pageContext.request.contextPath}/static/style/front/upload/act-f.jpg"/></a></div>
    </div><!--wrap-->  
</div>



<!--底部-->
<div class="footer">
   <div class="wrap">
      <div class="foot">
            <div class="foot-left fl">
                 <a href="">关于我们</a>
                 <a href="">加入我们</a>
                 <a href="contact.html">联系我们</a>
                 <a href="">媒体采访</a>
            </div>
            <div class="foot-c fl"><a href=""><img src="${pageContext.request.contextPath}/static/style/front/images/foot-logo.jpg"/></a></div>
            <div class="foot-right fr">
                 <a href="">同城活动</a>
                 <a href="">课程资讯</a>
                 <a href="">最新发布</a>
                 <a href="">热门文章</a>
            </div>
       </div> 
       <div class="foot-btm">高新出品</div>    
   </div>
</div>

<script src="js/jquery-1.11.1.min.js"></script>
<script src="js/jquery.SuperSlide.2.1.1.js"></script>
<script src="js/Action.js"></script>

<script type="text/javascript">
$(function(){
var nav=$(".header"); //得到导航对象
var win=$(window); //得到窗口对象
var sc=$(document);//得到document文档对象。
win.scroll(function(){
  if(sc.scrollTop()>=580){
    nav.addClass("head-cut"); 
   $(".head-cut").fadeIn(500); 
  }else{
   nav.removeClass("head-cut");
   $(".head-cut").fadeOut(500);
  }
})  
})
</script>
<script type="text/javascript">
  $(function ($) {
            $(".fullSlide").slide({
                titCell: ".hbox ul",
                mainCell: ".box ul",
                effect: "fold",
				mouseOverStop:false,
                autoPlay: true,
                autoPage: true,
                trigger: "click",
                startFun: function (i) {
                    var curLi = jQuery(".fullSlide .bd li").eq(i);
                    if (!!curLi.attr("_src")) {
                        curLi.css("background-image", curLi.attr("_src")).removeAttr("_src")
                    }
                }
            });
          
        });
      
</script>
</body>
</html>
